<?php

namespace beObject\MVC;

/**
 * This interface force to implements mapping methods when an object with
 * encapsulated objects is serialized.
 * @author Dany Mottier
 * @copyright MD Consult
 * @license http://www.gnu.org/licenses/gpl.html
 * @link http://www.beobject-framework.net/beobject/mvc/interfaces/serializable-interface/<br />
 * @package beObject\MVC
 * @version 3.0
 */
interface iSerializable {

  /**
   * This function forcess to implements the magic sleep method.<br />
   * This function should transform all encapsulated objects to a primitive variable.
   * @link http://www.beobject-framework.net/beobject/mvc/interfaces/serializable-__sleep/
   */
  function __sleep();

  /**
   * This function forces to implements the magic wakeup method.<br />
   * This function should restore all transformed variables to an object.
   * @link http://www.beobject-framework.net/beobject/mvc/interfaces/serializable-wakeup/
   */
  function __wakeup();
}

?>
